From: Florian Müllner Date: Tue, 29 Aug 2023 16:54:01 +0000 (+0200) Subject: status/network: Consider active connection for network's active state X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~320^2^2~32 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=0bfc6bd0c0c691a4764bb0e18f4921e98eb52662;p=gnome-shell.git status/network: Consider active connection for network's active state We currently show a network as connected when it includes the device's active access point. However when connected to an OWE transition network, the public AP redirects to a hidden AP that we ignore. To handle that case, also consider a network active when it includes the currently active connection. https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6918 Part-of: --- diff --git a/js/ui/status/network.js b/js/ui/status/network.js index 01aff61c3..e0f44d0f8 100644 --- a/js/ui/status/network.js +++ b/js/ui/status/network.js @@ -780,6 +780,7 @@ const WirelessNetwork = GObject.registerClass({ this._device.connectObject( 'notify::active-access-point', () => this.notify('is-active'), + 'notify::active-connection', () => this.notify('is-active'), this); this._accessPoints = new Set(); @@ -814,7 +815,14 @@ const WirelessNetwork = GObject.registerClass({ } get is_active() { - return this._accessPoints.has(this._device.activeAccessPoint); + if (this._accessPoints.has(this._device.activeAccessPoint)) + return true; + + const {activeConnection} = this._device; + if (activeConnection) + return this._connections.includes(activeConnection.connection); + + return false; } hasAccessPoint(ap) {